//
//  BBHomeTableViewCell.m
//  BlockBrowser
//
//  Created by Mac on 2018/3/30.
//  Copyright © 2018年 stoneobs@icloud.com. All rights reserved.
//

#import "BBHomeWebTableViewCell.h"
#import <WebKit/WebKit.h>
@interface  BBHomeWebTableViewCell()
@property(nonatomic, strong) WKWebView                     *webView;
@end
@implementation BBHomeWebTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    if (self == [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        [self configSubView];
    }
    return self;
}
+ (CGFloat)cellHeight{
    return 200;
}
- (void)setModel:(BBArticleModel *)model{
    _model = model;
    if (model.content.length) {
        [self.webView loadHTMLString:model.content baseURL:nil];
    }
   // self.contenLable.text = model.content;
}
#pragma mark --subView
- (void)configSubView{
    self.webView = [[WKWebView alloc] initWithFrame:CGRectMake(0, 0, UIScreenWidth, [BBHomeWebTableViewCell cellHeight])];
    self.webView.backgroundColor = TM_lineColor;
    [self addSubview:self.webView];
    

    
}

@end


